//函数的定义
function sorting(array) {
    for (let i = 0; i < array.length; i++) {
        for (let j = 0; j < array.length - 1; j++) {
            if (array[j] > array[j + 1]) {
                let temp = array[j];
                array[j] = array[j + 1];
                array[j + 1] = temp;
            }
        }
    }
    console.log(array.toString())
}


sorting([23, 43, 2, 24, 52, 244])

const maney = function () {

}

const rich = (x, y, z) => {
    return x * y * z;
}

const sum = _ => {

}

class person {
    job() {
        console.log("IT")

    }
    eat() {

    }
}

var per = new person();
per.job()


var a = [];
for (var i = 0; i < 10; i++) {
    a[i] = function () {
        console.log(i);
    }
}
a[6]();

var b = [];
for (let j = 0; j < 10; j++) {
    b[j] = function () {
        console.log(j);
    }
}
b[6]();
